/**
 * 贴图库样式
 */

/* 贴图库面板整体布局 - 确保高度自适应 */
#texture-library-panel {
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important; /* 关键：确保内部flex布局正常工作 */
    padding: 0 !important; /* 移除padding，让内部完全填充 */
    /* 继承拖拽调整的高度 */
}

/* 贴图库面板头部 - 固定高度 */
#texture-library-panel .panel-header {
    flex-shrink: 0 !important;
}

/* 确保拖拽手柄不占用布局空间 */
#texture-library-panel .resize-handle {
    position: absolute !important;
    z-index: 100 !important;
    pointer-events: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* 贴图库面板结构优化 - 确保列表贴合底边 */
#texture-library-panel .panel-content {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important; /* 隐藏溢出，让内部滚动 */
    min-height: 0 !important; /* 修复flex子元素高度问题 */
    max-height: 100% !important; /* 限制最大高度为100% */
    padding: 0 !important; /* 移除padding */
}

/* 贴图库面板body样式优化 */
#texture-library-body {
    display: flex !important;
    flex-direction: column !important;
    flex: 1 !important;
    min-height: 0 !important; /* 修复flex子元素高度问题 */
    max-height: 100% !important; /* 限制最大高度为100% */
    padding: 10px 15px 0 15px; /* 底部padding设为0，让列表贴底 */
    overflow-y: auto !important;
    overflow-x: hidden !important;
    /* 滚动条样式继承自.panel-body */
}

/* 贴图库搜索框 */
.texture-library-search {
    position: relative;
    margin-bottom: 12px;
    flex-shrink: 0; /* 固定尺寸，不收缩 */
}

.texture-search-input {
    width: 100%;
    padding: 8px 32px 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: #fff;
    font-size: 13px;
    outline: none;
    transition: all 0.2s ease;
}

.texture-search-input:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(108, 204, 153, 0.5);
}

.texture-search-input::placeholder {
    color: #666;
}

.texture-search-clear {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #999;
    font-size: 16px;
    cursor: pointer;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.texture-search-clear:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* 上传按钮样式 */
.header-action-btn {
    background: rgba(108, 204, 153, 0.1);
    border: 1px solid rgba(108, 204, 153, 0.2);
    border-radius: 6px;
    color: #6c9;
    font-size: 16px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    margin-right: 8px;
}

.header-action-btn:hover {
    background: rgba(108, 204, 153, 0.2);
    border-color: #6c9;
}

/* 贴图库统计信息 */
.texture-library-stats {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    margin-bottom: 16px;
    flex-shrink: 0; /* 固定尺寸，不收缩 */
}

.texture-library-stats .stats-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.texture-library-stats .stats-label {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
}

.texture-library-stats .stats-value {
    font-size: 20px;
    font-weight: bold;
    color: #fff;
}

/* 贴图列表容器 - 网格布局 */
.texture-library-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 8px;
    padding: 4px 4px 15px 4px; /* 底部添加15px padding，内容不紧贴底边 */
    /* 自动填充行以适应内容 */
    grid-auto-rows: max-content;
    /* 填充剩余空间 */
    flex: 1;
    /* 对齐到顶部 */
    align-content: start;
    /* 移除滚动条，使用外层panel-body的滚动 */
}

/* 空状态 */
.texture-library-list .empty-state {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
}

.texture-library-list .empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.texture-library-list .empty-text {
    font-size: 16px;
    color: #999;
    margin-bottom: 8px;
}

.texture-library-list .empty-hint {
    font-size: 12px;
    color: #666;
}

/* 贴图列表项 - 卡片式布局 */
.texture-library-item {
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    transition: all 0.2s ease;
    cursor: pointer;
}

.texture-library-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(108, 204, 153, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* 贴图预览 - 卡片顶部图片 */
.texture-preview {
    position: relative;
    width: 100%;
    height: 80px;
    background: rgba(0, 0, 0, 0.5);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.texture-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 引用数量徽章 */
.texture-ref-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(108, 204, 153, 0.9);
    color: #000;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 9px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 2px;
}

.texture-ref-badge.ref-zero {
    background: rgba(136, 136, 136, 0.9);
    color: #fff;
}

/* 贴图信息 - 卡片底部信息区 */
.texture-info {
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center; /* 所有内容居中对齐 */
}

.texture-name {
    font-size: 11px;
    font-weight: 500;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
    width: 100%; /* 占满宽度 */
    text-align: center; /* 文本居中 */
}

.texture-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 9px;
    align-items: center; /* 所有子项居中 */
    width: 100%; /* 占满宽度 */
}

.texture-dimension {
    color: #6c9;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center; /* 居中对齐 */
    gap: 4px;
}

.texture-size {
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center; /* 居中对齐 */
    gap: 4px;
}

.texture-reference {
    color: #6c9;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center; /* 居中对齐 */
    gap: 4px;
}

.texture-reference.ref-zero {
    color: #888;
}

/* 贴图操作按钮 - 卡片底部按钮组 */
.texture-actions {
    display: flex;
    gap: 4px;
    padding: 0 6px 6px 6px;
}

.texture-action-btn {
    flex: 1;
    height: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    cursor: pointer;
    font-size: 10px;
    color: #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    transition: all 0.2s ease;
}

.texture-action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.texture-action-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.texture-action-btn:disabled:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.texture-action-btn.delete-btn:hover:not(:disabled) {
    background: rgba(255, 77, 77, 0.2);
    border-color: rgba(255, 77, 77, 0.3);
    color: #ff6b6b;
}

.texture-action-btn.view-btn {
    background: rgba(108, 204, 153, 0.1);
    border-color: rgba(108, 204, 153, 0.2);
    color: #6c9;
}

.texture-action-btn.view-btn:hover {
    background: rgba(108, 204, 153, 0.2);
    border-color: rgba(108, 204, 153, 0.3);
}

/* 贴图引用详情对话框 */
.texture-ref-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

.texture-ref-dialog-content {
    background: #2a2a2a;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

.texture-ref-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.texture-ref-dialog-header h3 {
    margin: 0;
    font-size: 16px;
    color: #fff;
}

.texture-ref-dialog-header .close-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 24px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.texture-ref-dialog-header .close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.texture-ref-dialog-body {
    padding: 20px;
    overflow-y: auto;
}

.texture-ref-info {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
}

.texture-ref-preview {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 4px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.5);
}

.texture-ref-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.texture-ref-details {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
}

.texture-ref-name {
    font-size: 16px;
    font-weight: 500;
    color: #fff;
}

.texture-ref-count {
    font-size: 12px;
    color: #6c9;
}

.texture-ref-list h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    color: #fff;
}

.texture-ref-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.texture-ref-list li {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    font-size: 12px;
    color: #ccc;
    font-family: monospace;
}

/* 贴图预览对话框（放大查看） */
.texture-preview-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

.texture-preview-dialog-content {
    background: #2a2a2a;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

.texture-preview-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.texture-preview-dialog-header h3 {
    margin: 0;
    font-size: 16px;
    color: #fff;
}

.texture-preview-dialog-body {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex: 1;
}

.texture-preview-dialog-body img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 4px;
}

.texture-preview-dialog-footer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 12px;
    color: #999;
}

.texture-preview-dialog-footer > div {
    display: flex;
    gap: 8px;
}

/* 引用材质标签样式 */
.texture-preview-dialog-footer .material-tag {
    padding: 4px 10px;
    background: rgba(108, 204, 153, 0.15);
    border: 1px solid rgba(108, 204, 153, 0.3);
    border-radius: 4px;
    font-size: 11px;
    color: #6c9;
    font-family: monospace;
}

/* 动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 滚动条样式 */
.texture-library-list::-webkit-scrollbar {
    width: 6px;
}

.texture-library-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.texture-library-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.texture-library-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ============================
   贴图选择对话框（材质编辑器用）
   ============================ */
.texture-select-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

.texture-select-dialog-content {
    background: #2a2a2a;
    border-radius: 8px;
    width: 90%;
    max-width: 700px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

.texture-select-dialog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.texture-select-dialog-header h3 {
    margin: 0;
    font-size: 18px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.texture-select-dialog-header .close-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 24px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.texture-select-dialog-header .close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.texture-select-dialog-search {
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.texture-select-dialog-search input {
    width: 100%;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.texture-select-dialog-search input:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(108, 204, 153, 0.5);
}

.texture-select-dialog-search input::placeholder {
    color: #666;
}

.texture-select-dialog-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
    min-height: 300px;
}

.texture-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.texture-select-item {
    position: relative;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 2px solid transparent;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
}

.texture-select-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(108, 204, 153, 0.3);
    transform: translateY(-2px);
}

.texture-select-item.selected {
    border-color: #6c9;
    background: rgba(108, 204, 153, 0.2);
    box-shadow: 0 0 0 2px rgba(108, 204, 153, 0.3);
    position: relative;
}

.texture-select-item-preview {
    width: 100%;
    height: 140px;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.texture-select-item-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.texture-select-item-info {
    padding: 10px;
}

.texture-select-item-name {
    font-size: 13px;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
    font-weight: 500;
}

.texture-select-item-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.texture-select-item-size {
    font-size: 11px;
    color: #888;
}

.texture-select-item-dimension {
    font-size: 11px;
    color: #6c9;
    font-weight: 500;
}

.texture-select-item-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(108, 204, 153, 0.9);
    color: #000;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    display: none;
}

.texture-select-item.selected .texture-select-item-badge {
    display: block;
    animation: badgePulse 0.5s ease;
}

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.texture-select-dialog-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 12px;
}

.texture-select-dialog-footer-left {
    display: flex;
    gap: 8px;
}

.texture-select-dialog-footer-right {
    display: flex;
    gap: 8px;
}

.texture-select-upload-btn {
    padding: 10px 16px;
    background: rgba(108, 204, 153, 0.2);
    border: 1px solid rgba(108, 204, 153, 0.3);
    border-radius: 6px;
    color: #6c9;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.texture-select-upload-btn:hover {
    background: rgba(108, 204, 153, 0.3);
    border-color: #6c9;
}

.texture-select-confirm-btn,
.texture-select-cancel-btn {
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-weight: 500;
}

.texture-select-confirm-btn {
    background: #6c9;
    color: #000;
}

.texture-select-confirm-btn:hover:not(:disabled) {
    background: #7dd;
}

.texture-select-confirm-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.texture-select-cancel-btn {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.texture-select-cancel-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.texture-select-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
}

.texture-select-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.texture-select-empty-text {
    font-size: 16px;
    color: #999;
    margin-bottom: 8px;
}

.texture-select-empty-hint {
    font-size: 12px;
    color: #666;
}

/* 滚动条样式 - 绿色主题 */
.texture-select-dialog-body::-webkit-scrollbar {
    width: 8px;
}

.texture-select-dialog-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
}

.texture-select-dialog-body::-webkit-scrollbar-thumb {
    background: rgba(108, 204, 153, 0.3);
    border-radius: 4px;
    transition: background 0.2s ease;
}

.texture-select-dialog-body::-webkit-scrollbar-thumb:hover {
    background: rgba(108, 204, 153, 0.5);
}

/* ===============================================
   上传结果弹窗
   =============================================== */

.upload-result-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.upload-result-dialog {
    background: rgba(30, 30, 30, 0.98);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.upload-result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.upload-result-header h3 {
    margin: 0;
    font-size: 18px;
    color: #fff;
    font-weight: 600;
}

.upload-result-close {
    background: none;
    border: none;
    color: #999;
    font-size: 24px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.upload-result-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.upload-result-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.upload-result-body::-webkit-scrollbar {
    width: 8px;
}

.upload-result-body::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
}

.upload-result-body::-webkit-scrollbar-thumb {
    background: rgba(108, 204, 153, 0.3);
    border-radius: 4px;
}

.upload-result-body::-webkit-scrollbar-thumb:hover {
    background: rgba(108, 204, 153, 0.5);
}

.upload-result-summary {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.result-item {
    flex: 1;
    min-width: 150px;
    padding: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 500;
}

.result-item .icon {
    font-size: 24px;
}

.result-item.success {
    background: rgba(76, 175, 80, 0.15);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #4CAF50;
}

.result-item.warning {
    background: rgba(255, 152, 0, 0.15);
    border: 1px solid rgba(255, 152, 0, 0.3);
    color: #FF9800;
}

.result-item.error {
    background: rgba(244, 67, 54, 0.15);
    border: 1px solid rgba(244, 67, 54, 0.3);
    color: #F44336;
}

.upload-result-section {
    margin-bottom: 20px;
}

.upload-result-section:last-child {
    margin-bottom: 0;
}

.upload-result-section h4 {
    margin: 0 0 16px 0;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.file-list {
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.file-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px 18px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s ease;
}

.file-item:last-child {
    border-bottom: none;
}

.file-item:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateX(4px);
}

.file-item-icon {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

.file-item-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.file-item-name {
    font-size: 14px;
    font-weight: 500;
    color: #fff;
    word-break: break-all;
    line-height: 1.4;
}

.file-item-reason {
    font-size: 12px;
    line-height: 1.5;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
    align-self: flex-start;
}

.warning-reason {
    background: rgba(255, 152, 0, 0.15);
    color: #FFB74D;
    border-left: 3px solid #FF9800;
}

.error-reason {
    background: rgba(244, 67, 54, 0.15);
    color: #EF5350;
    border-left: 3px solid #F44336;
}

.upload-result-footer {
    padding: 16px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: flex-end;
}

.upload-result-footer .btn-confirm {
    padding: 10px 24px;
    background: rgba(108, 204, 153, 0.2);
    border: 1px solid rgba(108, 204, 153, 0.3);
    border-radius: 6px;
    color: #6c9;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.upload-result-footer .btn-confirm:hover {
    background: rgba(108, 204, 153, 0.3);
    border-color: #6c9;
}

